paths:
- mutter
- build
+ - subprojects/jasmine-gjs
test:
stage: test
common_test_env.set('GSETTINGS_BACKEND', 'memory')
common_test_env.set('XDG_CURRENT_DESKTOP', '')
+ jasmine = find_program('jasmine')
+
add_test_setup('default',
is_default: true,
env: common_test_env,
--- /dev/null
+[wrap-git]
+directory=jasmine-gjs
+url=https://github.com/ptomato/jasmine-gjs.git
+revision=c6aa28b3a3b16a3abb53e32825d83f836a2fed42
+
+[provide]
+program_names = jasmine
unit_testenv.append('GI_TYPELIB_PATH', st_typelib_path, separator: ':')
unit_tests = [
+]
+
+foreach test : unit_tests
+ test(test, jasmine,
+ args: [
+ '--module',
+ '--tap',
+ '--no-config',
+ '--interpreter', run_test,
+ 'unit/@0@.js'.format(test),
+ ],
+ suite: 'unit',
+ env: unit_testenv,
+ protocol: 'tap',
+ workdir: meson.current_source_dir())
+endforeach
+
+legacy_tests = [
'highlighter',
'injectionManager',
'insertSorted',
'versionCompare',
]
-foreach test : unit_tests
+foreach test : legacy_tests
test(test, run_test,
args: 'unit/@0@.js'.format(test),
suite: 'unit',
--- /dev/null
+---
+# SPDX-License-Identifier: MIT OR LGPL-2.0-or-later
+# SPDX-FileCopyrightText: 2024 Florian Müllner <fmuellner@gnome.org>
+rules:
+ jsdoc/require-jsdoc: 'off'
+globals:
+ jasmine: readonly
+ afterAll: readonly
+ afterEach: readonly
+ beforeAll: readonly
+ beforeEach: readonly
+ describe: readonly
+ expect: readonly
+ expectAsync: readonly
+ fail: readonly
+ fdescribe: readonly
+ fit: readonly
+ it: readonly
+ pending: readonly
+ setSpecProperty: readonly
+ setSuiteProperty: readonly
+ spyOn: readonly
+ spyOnAllFunctions: readonly
+ spyOnProperty: readonly
+ xdescribe: readonly
+ xit: readonly